import service from ".";

const classifyApi={

    //新增
    insertClassify(classify){
        return service.post('/admin/classify',classify);
    },
    //删除
    deleteClassify(cid){
        return service.delete(`/admin/classify${cid}`);
    },
    //修改
    updateClassify(classify){
        return service.put('/admin/classify', classify);
    },
    //查询所有
    selectAll(){
        return service.get('/admin/classify');
    },
    //根据Id查询
    selectCid(cid){
        return service.get(`/admin/classify/${cid}`);
    },
    //搜索框中查询
    selectCAndB(cid){
        return service.get('/admin/classify', cid);
    }
}
export default classifyApi;